package com.gitee.form_token.common;

import java.util.HashMap;
import java.util.Map;

public class Const {

	public final static String loginErrorMsg = "账号或密码错误";
	public final static String loginNullMsg = "账号或密码不能为空";

	public final static String Authorization = "Authorization";

	// JWT签发者 -- 管理系统
	public final static String WebIssuerKey = "Y3l0cC5jbg==";

	// JWT签发者 -- 前端App
	public final static String AppIssuerKey = "Y3l0cC5jbg==";

	private final static Map<Integer, String> statusMap = new HashMap<>();

	static {
		statusMap.put(400, "参数异常");
		statusMap.put(401, "令牌异常");
		statusMap.put(403, "暂无权限");
		statusMap.put(404, "无效地址");
		statusMap.put(500, "服务器错误");
	}

	public static String getMsg(int status) {
		return statusMap.get(status);
	}

}
